package com.singleton.demo;

/**
 * Created by Administrator on 2017/6/1.
 */
class TaskManager {
    private static TaskManager tm = null;
    private TaskManager(){
        System.out.println("TaskManager init");
    }
    public void displayProcesses(){
        System.out.println("display processes");
    }
    public void displayServices(){
        System.out.println("display services");
    }
    public static TaskManager getInstance(){
        if(tm == null){
            tm = new TaskManager();
        }
        return tm;
    }
}
